<div class="doc-content">



<header class="api-profile-header" >
  <h2 class="md-display-1" >{{currentDoc.name}} API Documentation</h2>
  
</header>



<div layout="row" class="api-options-bar with-icon"></div>


<div class="api-profile-description">
  <p>The <code>md-select-on-focus</code> directive allows you to automatically select the element&#39;s input text on focus.</p>
<p><h3>Notes</h3></p>
<ul>
<li>The use of <code>md-select-on-focus</code> is restricted to <code>&lt;input&gt;</code> and <code>&lt;textarea&gt;</code> elements.</li>
</ul>

</div>


<div>
  

  

  
  <section class="api-section">
    <h2 id="Usage">Usage</h2>
  
    <p><h3>Using with an Input</h3></p>
<hljs lang="html">

<md-input-container>
  <label>Auto Select</label>
  <input type="text" md-select-on-focus>
</md-input-container>
</hljs>

<p><h3>Using with a Textarea</h3></p>
<hljs lang="html">

<md-input-container>
  <label>Auto Select</label>
  <textarea md-select-on-focus>This text will be selected on focus.</textarea>
</md-input-container>

</hljs>
  
  </section>
  
  


  
</div>


</div>
